package com.eco.fanliapp.service;


import com.baomidou.mybatisplus.extension.service.IService;
import com.eco.fanliapp.common.response.ServerResponse;
import com.eco.fanliapp.entity.SyBlacklist;
import com.eco.fanliapp.vo.UserVO;

import java.util.List;

/**
 * <p>
 * 用户黑名单表 服务类
 * </p>
 *
 * @author jobob
 * @since 2019-09-09
 */
public interface ISyBlacklistService extends IService<SyBlacklist> {

    /**
     * 添加黑名单
     * @param syBlacklist
     * @return
     */
    ServerResponse addSyBlacklist(SyBlacklist syBlacklist);

    /**
     * 根据用户id 和 上级邀请码 校验用户是否是黑名单用户
     * @param userId
     * @return
     */
    boolean userCheck(Long userId,String superInviteCode);


    /**
     * 保存黑名单
     * @param syBlacklist
     * @return
     */
    ServerResponse saveSyBlacklist(SyBlacklist syBlacklist, UserVO authentication);


    /**
     * 洗白
     * @param syBlacklist
     * @return
     */
    ServerResponse updateSyBlacklist(SyBlacklist syBlacklist,UserVO authentication);

    /**
     * 查询所有的黑名单用户
     * @return
     */
    List<SyBlacklist>  selectAllSyBlacklist();

    /**
     * 校验用户是否在黑名单
     * @param userId
     * @return
     */
    Boolean verifyUserAgreement(Long userId);
}
